<?php
$fixedlink = './module/photo/STEP/';
?>
<link href="<?=$fixedlink ?>default.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="<?=$fixedlink ?>swfupload.js"></script>
<script type="text/javascript" src="<?=$fixedlink ?>swfupload.queue.js"></script>
<script type="text/javascript" src="<?=$fixedlink ?>fileprogress.js"></script>
<script type="text/javascript" src="<?=$fixedlink ?>handlers.js"></script>
<script type="text/javascript">
		var upload1;

function loadscript() {
			upload1 = new SWFUpload({
				// Backend Settings
				upload_url: "<?=$fixedlink ?>upload.php",
				post_params: {"PHPSESSID" : "<?php echo session_id(); ?>", "folder_upload" : "<?=$path ?>", "id": <?=$id ?>},

				// File Upload Settings
				file_size_limit : "5200",	// 5MB
				file_types : "*.jpg;*.JPG",
				file_types_description : "Picture JPEG",
				file_upload_limit : "0",
				file_queue_limit : "0",

				// Event Handler Settings (all my handlers are in the Handler.js file)
				file_dialog_start_handler : fileDialogStart,
				file_queued_handler : fileQueued,
				file_queue_error_handler : fileQueueError,
				file_dialog_complete_handler : fileDialogComplete,
				upload_start_handler : uploadStart,
				upload_progress_handler : uploadProgress,
				upload_error_handler : uploadError,
				upload_success_handler : uploadSuccess,
				upload_complete_handler : uploadComplete,

				// Button Settings
				button_image_url : "<?=$fixedlink ?>images/btupload.png",
				button_placeholder_id : "spanButtonPlaceholder1",
				button_width: 171,
				button_height: 31,
				button_text: '<span class="theFont"> Select images & Upload </span>',
				button_text_style: ".theFont { font-size: 13; font-family: Arial;}",
				button_text_left_padding: 12,
				button_text_top_padding: 5,
				
				// Flash Settings
				flash_url : "<?=$fixedlink ?>images/swfupload.swf",
				

				custom_settings : {
					progressTarget : "fsUploadProgress1",
					cancelButtonId : "btnCancel1"
				},
				
				// Debug Settings
				debug: false
			});
}

</script>
<div id="content_upload">
	<form id="form1" action="index.php" method="post" enctype="multipart/form-data">
		<table style="margin-top:0px;">
			<tr valign="top">
				<td>
					<div>
						<div style="padding-left: 5px;">
							<span id="spanButtonPlaceholder1"></span>
							<input id="btnCancel1" type="button" value="Cancel Uploads" onClick="cancelQueue(upload1);" disabled="disabled" style="margin-top:4px;"/>
							<br />
						</div>
						<div class="fieldset flash" id="fsUploadProgress1"></div>
					</div>
				</td>
			</tr>
		</table>
	</form>
</div>
<script>loadscript();</script>